package aptech.ad02.homemain;

import com.example.danangtravel.R;
import com.example.danangtravel.Tbshopping_activity;
import com.example.danangtravel.R.id;
import com.example.danangtravel.R.layout;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.View;
import android.widget.Toast;
import aptech.ad02.restaurant.Activity_RestaurantListView;

public class Home extends Activity {

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.home);
	}

	public void onClick(View view) {
		
		
		switch (view.getId()) {
		// Button restaurant
		case R.id.khachsan:
			Toast.makeText(view.getContext(), "khach san", 1000).show();
			Intent intent_Restaurant = new Intent(view.getContext(),Activity_RestaurantListView.class);
			startActivity(intent_Restaurant);
			break;

		// Button du lich
		case R.id.dulich:
			Toast.makeText(view.getContext(), "du lich", 1000).show();
			break;
			
		// Button am thuc
		case R.id.amthuc:
			Toast.makeText(view.getContext(), "am thuc", 1000).show();
			break;

		// Button mua sam
		case R.id.muasam:
			//Toast.makeText(view.getContext(), "mua sam", 1000).show();
			Intent intent = new Intent(view.getContext(),Tbshopping_activity.class);
			startActivity(intent);
			
			overridePendingTransition(R.anim.righttoleft, R.anim.lefttoright);
			break;
		
		//Button taxi
		case R.id.taxi:
			Toast.makeText(view.getContext(), "taxi", 1000).show();
			break;
			
		//Button atm
		case R.id.atm:
			Toast.makeText(view.getContext(), "atm", 1000).show();
			break;
			
		//Button huong dan	
		case R.id.huongdan:
			Toast.makeText(view.getContext(), "huong dan", 1000).show();
			break;
			
		//Button lien he
		case R.id.lienhe:
			Toast.makeText(view.getContext(), "lien he", 1000).show();
			break;
			
		//Button gioi thieu
		case R.id.gioithieu:
			Toast.makeText(view.getContext(), "gioi thieu", 1000).show();
			break;
		}
	}
}
